package com.ratta.supernote.plugin.sticker.lib.utils;

import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Canvas;
import android.graphics.drawable.Drawable;
import android.nfc.Tag;
import android.util.Log;

import java.io.File;


public class ImageResUtils {
    private final static String TAG = "ImageResUtils";
   private static Bitmap itemSelected;
   private static Bitmap itemNoSelected;

   public static Bitmap getItemSelected(Context context){
       if(itemSelected != null) {
           return  itemSelected;
       }
       String imagePath = context.getFilesDir().getAbsolutePath() + File.separator + "plugins"
               +File.separator + "a5db6166e8fe8e17"+File.separator+"ic_select_black.png";
       Log.i(TAG,"getItemSelected imagePath:"+imagePath);
       itemSelected = BitmapFactory.decodeFile(imagePath);
       return  itemSelected;
   }

   public static  Bitmap getItemNoSelected(Context context) {
       if(itemNoSelected != null) {
           return  itemNoSelected;
       }
       String imagePath = context.getFilesDir().getAbsolutePath() + File.separator + "plugins"
               +File.separator + "a5db6166e8fe8e17"+File.separator+"ic_select_no.png";
       Log.i(TAG,"getItemNoSelected imagePath:"+imagePath);
       itemNoSelected = BitmapFactory.decodeFile(imagePath);
       return  itemNoSelected;
   }
}
